package team.first.movieapiv2pro.doc;

import dev.morphia.annotations.Entity;
import dev.morphia.annotations.Id;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.experimental.Accessors;
import org.bson.types.ObjectId;

import java.time.LocalDate;
import java.util.List;

@Entity(value = "staff", useDiscriminator = false)
@Data
@Accessors(chain = true)
@ApiModel("演职人员文档")
public class StaffDoc {

    @Id
    @ApiModelProperty(value = "文档编号", example = "619f48fae2f3f25894660f75")
    private ObjectId objectId;

    @ApiModelProperty(value = "员工编号", example = "121111")
    private Integer id;

    @ApiModelProperty(value = "中文名", example = "小明")
    private String chineseName;

    @ApiModelProperty(value = "英文名", example = "XiaoMing")
    private String englishName;

    @ApiModelProperty(value = "性别", example = "男")
    private String gender;

    @ApiModelProperty(value = "地区", example = "北美")
    private String region;

    @ApiModelProperty(value = "生日", example = "0214")
    private LocalDate birthday;

    @ApiModelProperty(value = "简介", example = "勤快")
    private String summary;

    @ApiModelProperty(value = "照片地址", example = "www.haibao.com")
    private String avatarUrl;

    @ApiModelProperty(value = "照片名", example = "小明自拍之臭美")
    private String avatar;

    @ApiModelProperty(value = "参演的电影列表", example = "小学数学书合集")
    private List<FilmographyDoc> acted;

    @ApiModelProperty(value = "导演的电影列表", example = "故意做错数学题之年度大戏")
    private List<FilmographyDoc> directed;

}
